Availability Property

Summary
Gets or sets the availability.
Syntax
C#
C++/CLI
public InstanceAvailability Availability { get; } 
public: 
property InstanceAvailability Availability { 
   InstanceAvailability get(); 
} 

Property Value

A InstanceAvailability object that represents the availability.

Example
C#
using Leadtools; 
using Leadtools.Dicom.Scu; 
using Leadtools.Dicom.Scu.Common; 
using Leadtools.Dicom; 
using Leadtools.Dicom.Common.DataTypes; 
using Leadtools.Dicom.Common.DataTypes.Status; 
 
 
public void FindInstances() 
{ 
   DicomEngine.Startup(); 
   DicomNet.Startup(); 
 
   QueryRetrieveScu findInstance = new QueryRetrieveScu(); 
   FindQuery query = new FindQuery(); 
   DicomScp scp = new DicomScp(); 
 
   // 
   // Change these parameters to reflect the calling AETitle. 
   // 
 
   findInstance.AETitle = CLIENT_AE_TITLE; 
   findInstance.HostPort = CLIENT_PORT; 
   findInstance.HostAddress = Dns.GetHostEntry(Dns.GetHostName()).AddressList.FirstOrDefault(ip => ip.AddressFamily == AddressFamily.InterNetwork); 
 
   // 
   // Change these parameters to reflect the called AETitle (server). 
   // 
 
   scp.AETitle = SCP_AE_TITLE; 
   scp.Port = SCP_PORT; 
   scp.Timeout = 60; 
   scp.PeerAddress = Dns.GetHostEntry(Dns.GetHostName()).AddressList.FirstOrDefault(ip => ip.AddressFamily == AddressFamily.InterNetwork);  // IPAddress.Parse("10.1.1.96"); 
 
   query.QueryLevel = QueryLevel.Image; 
   query.StudyInstanceUID = "1.2.840.114257.1.1.69808.20200724.201715.6635418.1"; 
   query.SeriesInstanceUID = "1.2.840.114257.1.1.69808.20200724.201715.7983872.4"; 
   findInstance.BeforeCFind += new BeforeCFindDelegate(findInstance_BeforeCFind); 
   findInstance.MatchInstance += new MatchInstanceDelegate(findInstance_MatchInstance); 
   findInstance.AfterCFind += new AfterCFindDelegate(findInstance_AfterCFind); 
   findInstance.Find(scp, query, true, Path.Combine(LEAD_VARS.ImagesDir, "DICOM", "Image1.dcm")); 
 
   DicomNet.Shutdown(); 
   DicomEngine.Shutdown(); 
} 
 
void findInstance_BeforeCFind(object sender, BeforeCFindEventArgs e) 
{ 
   Console.WriteLine("Before CFind: " + e.QueryLevel.ToString()); 
} 
 
void findInstance_MatchInstance(object sender, MatchEventArgs<CompositeObjectInstance> e) 
{ 
   Console.WriteLine("SOP Instance UID: " + e.Info.SOPInstanceUID); 
   Console.WriteLine("SOP Class UID: " + e.Info.SOPClassUID); 
   Console.WriteLine("Instance #: " + e.Info.InstanceNumber); 
   Console.WriteLine("Availability: " + e.Availability); 
} 
 
void findInstance_AfterCFind(object sender, AfterCFindEventArgs e) 
{ 
   Debug.Assert(e.Status == DicomCommandStatusType.Success); 
} 
 
 
static class LEAD_VARS 
{ 
   public const string ImagesDir = @"C:\LEADTOOLS23\Resources\Images"; 
} 
Requirements

Target Platforms

Help Version 23.0.2024.7.31
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2024 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.Dicom.Scu Assembly
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.